C++中將string類型轉化為int類型 寫程序需要將string轉化為int,所以就探索了一下。 方法一:atoi函數 atoi函數將字符串轉化為整數,注意需要stdlib庫。所以就嘗試了一下: ...